//
//  KeRenUserCell.m
//  KEREN
//
//  Created by chenliang on 2023/8/24.
//

#import "KeRenUserCell.h"
@interface KeRenUserCell()
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *titleLb_y_center;

@end

@implementation KeRenUserCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

-(void)setUserCellStyle:(UserCellStyle)style{
    if(style == UserCellStyle_Common){
        self.titleLb_y_center.constant  = 0;
        self.subTitleLb.hidden = YES;
    }else if(style == UserCellStyle_SubTitle){
        self.titleLb_y_center.constant = -(2 + self.subTitleLb.bounds.size.height)/2.0;
        self.subTitleLb.hidden = NO;
    }else{
        self.titleLb_y_center.constant  = 0;
        self.subTitleLb.hidden = YES;
    }
}
@end
